<template>
  <div class="page-container">
    <div class="flex_cell flex_col over_auto"  v-loading="loading">
      
    </div>
    <div style="padding-left: 140px ;padding-top: 10px;">
      <el-button @click="return_page_back" >{{ $tt('label_close') }}</el-button>
    </div>

  </div>
</template>
<script>

let default_obj = {
  title: null,//	string 	标题
  content: null,//	string 	内容
}
import router_params from '@/mixin/router_params';
import role_system_mixin from '@/mixin/role_system_mixin';


export default {
  mixins: [router_params, role_system_mixin],
  components: {},

  data() {
    return {
      loading: false,
 
      form: _.cloneDeep(default_obj),
   
    };
  },

  mounted() {
   
  },
  beforeDestroy() {

  },
  methods: {


    init_data_default(into_params) {
      this.form = _.cloneDeep(default_obj)
      if (this.edit) {
        if (into_params.id) {
          this.loading = true
          this.$ajax({
            url: this.$url['mms/skuDetail'],
            method: 'post',
            data: { id: into_params.id },
            success: (res) => {
              if (!res.data) return this.$message.error(this.$tt("label_data_loss"))

              this.$nextTick(() => {
              })
              this.fixTabLabel()
            },
            complete: () => {
              this.loading = false
            }
          })
        }
      } else {
        this.sku_categ_cascader = true
      }
      this.fixTabLabel()
    },
    fixTabLabel() {
      if (this.edit && !!this.form.id) {
        this.$emit("tagModifyLabel", { _key: 'label_name_code', name: this.$tt('label_edit_message'), code: this.form.title || "" })

      } else {
        this.$emit("tagModifyLabel", "label_new_message")
      }
    },

  }
};

</script>
<style>

</style>
